package route

import (
	"Server/logic/userLogic"
	"Server/middleware"
	"github.com/gin-gonic/gin"
)

func CollectRoute(r *gin.Engine) *gin.Engine {
	r.Use(middleware.CORSMiddleware(), middleware.RecoverMiddleware()) //使用中间件
	v1 := r.Group("/text")
	{
		v1.GET("/register", userLogic.Register)
		v1.GET("/login", userLogic.Login)
	}
	return r
}
